<template>
  <div id="main">
    <!-- <h3>星期一</h3> -->
    <!-- 顶部 ，设置，客服按钮 -->
    <van-row type="flex" justify="end" class="top">
      <van-col span="3">
        <router-link to="/set">设置</router-link>
      </van-col>
      <van-col span="3">
        <router-link to="#">客服</router-link>
      </van-col>
    </van-row>
    <!-- 会员信息 -->
    <div class="myMessage">
      <div class="top">
        <router-link to="/myinformation">
          <div class="message">
            <div class="headerImg">
              <img
                src="https://upload.jianshu.io/users/upload_avatars/18090590/06156500-076b-499a-8191-b71e2d2581d1.jpg?imageMogr2/auto-orient/strip|imageView2/1/w/96/h/96/format/webp"
                alt="头像"
              />
            </div>
            <div class="userName">用户名</div>
          </div>
        </router-link>
      </div>
      <div class="bot">这里是一下优惠券什么的乱七八糟</div>
    </div>
    <!-- 购物车收藏 -->
    <van-row type="flex" justify="end" class="cart_collection">
      <van-col span="5">
        <router-link to="/cart">
          <p><van-icon name="shopping-cart-o" />购物车</p>
        </router-link>
      </van-col>
      <van-col span="5">
        <router-link to="#">
          <p><van-icon name="star-o" />收藏</p>
        </router-link>
      </van-col>
      <van-col span="5">
        <router-link to="#">
          <p><van-icon name="send-gift-o" />足迹</p>
        </router-link>
      </van-col>
      <van-col span="5">
        <router-link to="#">
          <p><van-icon name="pending-payment" />红包卡券</p>
        </router-link>
      </van-col>
    </van-row>
    <!-- 我的订单 -->
    <div class="myorder">
      <div class="top">
        <van-row type="flex" justify="space-between">
          <van-col span="6">
            <router-link to="#">我的订单</router-link>
          </van-col>
          <van-col span="6">
            <router-link to="#">全部订单></router-link>
          </van-col>
        </van-row>
      </div>
      <van-row type="flex" justify="space-between" class="sameLayout">
        <van-col span="4">
          <router-link to="#">
            <p><van-icon name="shopping-cart-o" badge="2" />待付款</p>
          </router-link>
        </van-col>
        <van-col span="4">
          <router-link to="#">
            <p><van-icon name="logistics" badge="9" />待收货</p>
          </router-link>
        </van-col>
        <van-col span="4">
          <router-link to="#">
            <!-- <p> -->
              <van-icon name="underway-o" badge="3" />待使用
            <!-- </p> -->
          </router-link>
        </van-col>
        <van-col span="4">
          <router-link to="#">
            <p><van-icon name="chat-o" badge="5" />待评价</p>
          </router-link>
        </van-col>
        <van-col span="4">
          <router-link to="#">
            <p><van-icon name="refund-o" badge="3" />售后</p>
          </router-link>
        </van-col>
      </van-row>
    </div>
    <!-- 贷款广告 -->
    <van-row type="flex" justify="space-between" class="sameLayout1">
      <van-col span="4">
        <router-link to="#">
          <p>
            <span style="font-size: 18px">5000</span>元<br /><span
              >美团借钱</span
            >
          </p>
        </router-link>
      </van-col>
      <van-col span="4">
        <router-link to="#">
          <p>
            <span style="font-size: 18px"> <van-icon badge="1" />1 </span
            >个特权<br /><span>未领取</span>
          </p>
        </router-link>
      </van-col>
      <van-col span="4">
        <router-link to="#">
          <p><van-icon name="credit-pay" />信用卡额度</p>
        </router-link>
      </van-col>
      <van-col span="4">
        <router-link to="#">
          <p><van-icon name="cash-on-deliver" />数字人民币</p>
        </router-link>
      </van-col>
      <van-col span="4">
        <router-link to="#">
          <p><van-icon name="pending-payment" />我的钱包</p>
        </router-link>
      </van-col>
    </van-row>
    <!-- 彩色的广告区域 -->
    <div class="ads">
      <van-row>
        <van-col span="4"
          ><svg class="icon" aria-hidden="true">
            <use xlink:href="#icon-huafubing"></use>
          </svg>
          <span>领话费</span>
        </van-col>
        <van-col span="4"
          ><svg class="icon" aria-hidden="true">
            <use xlink:href="#icon-lvhanghuafei"></use>
          </svg>
          <span>提现100元</span>
        </van-col>
        <van-col span="4"
          ><svg class="icon" aria-hidden="true">
            <use xlink:href="#icon-she"></use>
          </svg>
          <span>贪吃蛇</span>
        </van-col>
        <van-col span="4"
          ><svg class="icon" aria-hidden="true">
            <use xlink:href="#icon-juzishu"></use>
          </svg>
          <span>免费领水果</span>
        </van-col>
        <van-col span="4"
          ><svg class="icon" aria-hidden="true">
            <use xlink:href="#icon-cantingxiaofei"></use>
          </svg>
          <span>小美餐厅</span>
        </van-col>
      </van-row>
      <van-row>
        <van-col span="4"
          ><svg class="icon" aria-hidden="true">
            <use xlink:href="#icon-a-17-01"></use>
          </svg>
          <span>种红包</span>
        </van-col>
        <van-col span="4"
          ><svg class="icon" aria-hidden="true">
            <use xlink:href="#icon-tiantianquan"></use>
          </svg>
          <span>爱消除</span>
        </van-col>
        <van-col span="4"
          ><svg class="icon" aria-hidden="true">
            <use xlink:href="#icon-qianbao"></use>
          </svg>
          <span>福利中心</span>
        </van-col>
        <van-col span="4"
          ><svg class="icon" aria-hidden="true">
            <use xlink:href="#icon-jianzhu_louceng"></use>
          </svg>
          <span>盖楼赚钱</span>
        </van-col>
        <van-col span="4"
          ><svg class="icon" aria-hidden="true">
            <use xlink:href="#icon-tianfuluo"></use>
          </svg>
          <span>美团小镇</span>
        </van-col>
      </van-row>
    </div>

    <Buttom-Tabbar></Buttom-Tabbar>
  </div>
</template>

<script>
import "@/assets/font-lp/iconfont.js";
export default {
  data() {
    return {
      active: 0,
    };
  },
  methods: {
    // 获取store状态管理中的user信息。
  },
  computed: {
    user() {
      return this.$store.getters.getUser;
    },
  },
};
</script>

<style lang="scss" scoped>
* {
  margin: 0;
  padding: 0;
  font-size: 14px;
}

.icon {
  width: 1em;
  height: 1em;
  vertical-align: -0.15em;
  fill: currentColor;
  overflow: hidden;
}

a {
  color: black;
}

a:hover {
  color: #1989fa;
}

#main {
  width: 100%;
  margin: 0 auto;
  background: #f4f4f4;
  padding-bottom: 10px;

  .top {
    width: 95%;
    height: 30px;
    line-height: 30px;
    margin-bottom: 5px;
  }

  .myMessage {
    height: 120px;
    background: #ffde36;
    margin-bottom: 10px;
    border-radius: 5px;
    overflow: hidden;

    .top {
      padding-left: 10px;
      margin-top: 10px;
      height: 80px;
      line-height: 80px;
      display: flex;
      justify-content: space-between;

      .message {
        width: 220px;
        display: flex;

        .headerImg {
          img {
            width: 100%;
            height: 100%;
          }

          width: 70px;
          height: 70px;
          border-radius: 50%;
          overflow: hidden;
          background: pink;
        }

        .userName {
          margin-left: 15px;
          width: 80px;
        }
      }

      .growCenter {
        width: 70px;
        background: pink;
      }
    }

    .bot {
      height: 40px;
    }
  }

  // 购物车&收藏夹
  .cart_collection {
    line-height: 40px;
    display: flex;
    justify-content: space-evenly;
    border-radius: 5px;
    background: white;
    margin-bottom: 10px;

    p {
      display: flex;
      flex-direction: column;
      justify-content: center;
    }

    // 我的订单
  }

  .van-icon {
    font-size: 26px;
  }

  // 我的订单
  .myorder {
    height: 120px;
    background: #ffffff;
    margin-bottom: 10px;
    border-radius: 5px;
    padding-top: 10px;
    .top {
      margin-top: 5px;
      margin-bottom: 15px;
    }
    p {
      margin-top: 5px;
      display: flex;
      flex-direction: column;
      justify-content: center;
    }
  }

  .sameLayout {
    font-size: 14px;
    margin-bottom: 10px;
    border-radius: 5px;
  }

  .sameLayout1 {
    height: 100px;
    font-size: 14px;
    background: white;
    border-radius: 5px;
    display: flex;
    align-items: center;
    margin-bottom: 10px;

    p {
      font-size: 12px;
    }
  }

  .van-col {
    display: flex;
    justify-content: center;
    .van-icon {
      display: flex;
      justify-content: center;
    }
  }

  // 广告区域
  .ads {
    height: 120px;
    background: #ffffff;
    border-radius: 5px;

    .van-row {
      height: 55px;
      display: flex;
      justify-content: space-between;
      align-items: center;
    }

    .van-col {
      margin-top: 10px;
      display: flex;
      flex-direction: column;
      justify-content: center;
      align-items: center;
      font-size: 24px;
      span {
        font-size: 12px;
      }
    }
  }
}
</style>